/*
 * @Description:
 * 
 * @Author: rendc
 * 
 * @Date: 2025-07-30 11:41:04
 * 
 * @LastEditors: rendc
 * 
 * @LastEditTime: 2025-07-30 11:59:40
 */
class Demo {
  public static int num;
  public static int staticSum;
  public int num1;

  public static void main(String[] args) {
    // 可以使用类名来访问，推荐用法
    Demo.num = 10;
    Demo demo = new Demo();
    System.out.println(demo);
    // 也可以对象来访问，但不推荐
    demo.num = 20;
    test();
    test1();
    test2();
  }

  public static void test() {
    test1();
    test2();
    System.out.println(staticSum);
    System.out.println(num1);
  }

  public static void test1() {
    System.out.println("test1");
  }

  public void test2() {
    System.out.println("test2");
    System.out.println(staticSum);
    System.out.println(num1);

  }
}
